package data
{
	import events.MutiPropertyEvent;
	
	import flash.events.EventDispatcher;
	import flash.geom.Point;
	import flash.utils.Dictionary;

	public class SoldierInfo extends MutiProCommitObject
	{
		public static var P_actions:String='actions';
		public static var P_avatar:String='avatar';
		public static var P_hp:String='hp';
		public static var P_weapon:String='weapon';

		public function SoldierInfo()
		{
		}
		
		protected var _actions:String;
		
		protected var _avatar:String;
		
		protected var _hp:int;
		
		protected var _weapon:String = '';
		
		protected var _position:Point;
		protected var _mobility:int;
		protected var _unitMobility:int;
		
		public var id:int;

		public function get actions():String
		{
			return _actions;
		}
		
		public function set actions(value:String):void
		{
			if (_actions == value)
				return;
			_lastPropertys[P_actions]=_actions;
			_actions=value;
			onPropertiesChanged(P_actions);
		}
		public function get avatar():String
		{
			return _avatar;
		}
		
		public function set avatar(value:String):void
		{
			if (_avatar == value)
				return;
			_lastPropertys[P_avatar]=_avatar;
			_avatar=value;
			onPropertiesChanged(P_avatar);
		}
		public function get hp():int
		{
			return _hp;
		}
		
		public function set hp(value:int):void
		{
			if (_hp == value)
				return;
			_lastPropertys[P_hp]=_hp;
			_hp=value;
			onPropertiesChanged(P_hp);
		}
		
		public function get weapon():String
		{
			return _weapon;
		}
		
		public function get range():Number
		{
			return 10;
		}
		
		public function set weapon(value:String):void
		{
			if (_weapon == value)
				return;
			_lastPropertys[P_weapon]=_weapon;
			_weapon=value;
			onPropertiesChanged(P_weapon);
		}

		public function get position():Point
		{
			return _position;
		}

		public function set position(value:Point):void
		{
			_position = value;
		}

		public function get mobility():int
		{
			return _mobility;
		}

		public function set mobility(value:int):void
		{
			_mobility = value;
		}

		public function get unitMobility():int
		{
			return _unitMobility;
		}

		public function set unitMobility(value:int):void
		{
			_unitMobility = value;
		}


	}
}